-
Notifications
You must be signed in to change notification settings - Fork 4
Prune zephyr manifest #30
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
…e-Space-Foundation/proves-core-reference into prune-zephyr-manifest
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR introduces a custom minimal West manifest for Zephyr and optimizes the CI/CD build process to significantly reduce build times by approximately 50%. The changes focus on including only the essential modules needed for RP2040/RP2350 development rather than the entire Zephyr ecosystem.
Key changes:
- Creates a minimal West manifest (
west.yml) with only RP2040/RP2350-specific modules - Updates the Makefile to use ARM-only toolchain installation for ~92% SDK size reduction
- Refactors CI workflow with intelligent caching and dependency management
- Adds comprehensive documentation for the new setup process
Reviewed Changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated 4 comments.
Show a summary per file
| File | Description |
|---|---|
| west.yml | New minimal manifest targeting only RP2040/RP2350 modules, reducing workspace size by ~80% |
| lib/zephyr-workspace/.west/config | Removes old West configuration to use new manifest |
| docs/additional-resources/west-manifest-setup.md | Comprehensive documentation for minimal setup, migration, and troubleshooting |
| Makefile | Updates Zephyr setup targets to use minimal modules and ARM-only toolchain |
| CMakeLists.txt | Adds BOARD_ROOT configuration for custom board support |
| .github/workflows/ci.yaml | Major CI refactor with intelligent caching and optimized dependency management |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
| - name: hal_st | ||
| revision: 9f81b4427e955885398805b7bca0da3a8cd9109c | ||
| path: lib/zephyr-workspace/modules/hal/st | ||
| groups: | ||
| - hal | ||
|
|
Copilot
AI
Oct 3, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The hal_st module is included but the comment in the documentation indicates it's for LIS2MDL and LSM6DSO sensors. Consider adding a comment explaining why this STM HAL is needed for RP2040/RP2350 builds or remove it if it's not actually required for the minimal setup.
| - name: hal_st | |
| revision: 9f81b4427e955885398805b7bca0da3a8cd9109c | |
| path: lib/zephyr-workspace/modules/hal/st | |
| groups: | |
| - hal |
Makefile
Outdated
| ##@ Dependencies | ||
| # Note: Zephyr setup uses minimal modules and ARM-only toolchain for RP2040/RP2350 | ||
| # This saves ~3-4 GB compared to full installation. See docs/additional-resources/west-manifest-setup.md | ||
| # Hello World! |
Copilot
AI
Oct 3, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This appears to be a test comment that should be removed as it doesn't provide any meaningful information about the Zephyr setup.
| # Hello World! |
.github/workflows/ci.yaml
Outdated
| echo "Submodule sizes:" | ||
| du -sh lib/fprime lib/fprime-zephyr lib/zephyr-workspace/zephyr 2>/dev/null || echo "Some submodules not found" | ||
| echo "" | ||
| echo "Zephyr modules size: $(du -sh lib/zephyr-workspace/modules lib/zephyr-workspace/bootloader 2>/dev/null | awk '{sum+=$1} END {print sum"M"}' || echo 'N/A')" |
Copilot
AI
Oct 3, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The awk command for summing directory sizes is incorrect. The du -sh output includes units (like 'M', 'G') that can't be directly summed. This will likely produce incorrect output or fail silently.
| echo "Zephyr modules size: $(du -sh lib/zephyr-workspace/modules lib/zephyr-workspace/bootloader 2>/dev/null | awk '{sum+=$1} END {print sum"M"}' || echo 'N/A')" | |
| echo "Zephyr modules size: $(du -sb lib/zephyr-workspace/modules lib/zephyr-workspace/bootloader 2>/dev/null | awk '{sum+=$1} END {print sum}' | numfmt --to=iec --suffix=B 2>/dev/null || echo 'N/A')" |
| # Skip both zephyr-setup and submodules since we cached them separately | ||
| make build -o zephyr-setup -o submodules |
Copilot
AI
Oct 3, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The -o flags attempt to skip make targets, but this syntax is for skipping files, not targets. Consider using a different approach like conditional logic in the Makefile or separate build commands that don't depend on these targets.
| # Skip both zephyr-setup and submodules since we cached them separately | |
| make build -o zephyr-setup -o submodules | |
| # Build, setup and submodules have already been handled (cached or run above) | |
| make build |
…-core-reference into prune-zephyr-manifest
nateinaction
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the zephyr module downloads are not being cached anymore because, at least locally, are being downloaded to a parent directory of the repo. They are indeed faster but and the builds are functional so I think this is an OK step forward but we should pend more time here to understand how to store the modules in the repo instead.
Improving CI Build Times
Description
This pull request adds a custom
west.ymlZephyr manifest and also refactors thebuildCI to significantly reduce the GitHub Actions Runtime!By my best estimate we are going to put that build time in about half!

How Has This Been Tested?
Screenshots / Recordings (if applicable)
Checklist
Further Notes / Considerations